package com.woniu.customer.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import lombok.Data;

/**
 * 
 * @TableName ecp_clients_reConsignees_unit
 */
@TableName(value ="ecp_clients_reConsignees_unit")
@Data
public class ReconsigneesUnit implements Serializable {
    /**
     * 收货单位ID
     */
    @TableId(type = IdType.AUTO)
    private Long consigneeId;

    /**
     * 客户ID
     */
    private Long customerId;

    /**
     * 收货单位
     */
    private String consigneeUnit;

    /**
     * 收货收票地址
     */
    private String deliveryAddress;

    /**
     * 收货/收票人
     */
    private String consignee;

    /**
     * 手机号
     */
    private String phone;

    /**
     * 运输方式
     */
    private Integer transportType;

    /**
     * 到站地址
     */
    private String arrivalAddress;

    /**
     * 是否跨区
     */
    private Integer status;

    /**
     * 收票单位
     */
    private String ticketUnit;

    /**
     * 客户名称
     */
    private String customerName;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        ReconsigneesUnit other = (ReconsigneesUnit) that;
        return (this.getConsigneeId() == null ? other.getConsigneeId() == null : this.getConsigneeId().equals(other.getConsigneeId()))
            && (this.getCustomerId() == null ? other.getCustomerId() == null : this.getCustomerId().equals(other.getCustomerId()))
            && (this.getConsigneeUnit() == null ? other.getConsigneeUnit() == null : this.getConsigneeUnit().equals(other.getConsigneeUnit()))
            && (this.getDeliveryAddress() == null ? other.getDeliveryAddress() == null : this.getDeliveryAddress().equals(other.getDeliveryAddress()))
            && (this.getConsignee() == null ? other.getConsignee() == null : this.getConsignee().equals(other.getConsignee()))
            && (this.getPhone() == null ? other.getPhone() == null : this.getPhone().equals(other.getPhone()))
            && (this.getTransportType() == null ? other.getTransportType() == null : this.getTransportType().equals(other.getTransportType()))
            && (this.getArrivalAddress() == null ? other.getArrivalAddress() == null : this.getArrivalAddress().equals(other.getArrivalAddress()))
            && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
            && (this.getTicketUnit() == null ? other.getTicketUnit() == null : this.getTicketUnit().equals(other.getTicketUnit()))
            && (this.getCustomerName() == null ? other.getCustomerName() == null : this.getCustomerName().equals(other.getCustomerName()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getConsigneeId() == null) ? 0 : getConsigneeId().hashCode());
        result = prime * result + ((getCustomerId() == null) ? 0 : getCustomerId().hashCode());
        result = prime * result + ((getConsigneeUnit() == null) ? 0 : getConsigneeUnit().hashCode());
        result = prime * result + ((getDeliveryAddress() == null) ? 0 : getDeliveryAddress().hashCode());
        result = prime * result + ((getConsignee() == null) ? 0 : getConsignee().hashCode());
        result = prime * result + ((getPhone() == null) ? 0 : getPhone().hashCode());
        result = prime * result + ((getTransportType() == null) ? 0 : getTransportType().hashCode());
        result = prime * result + ((getArrivalAddress() == null) ? 0 : getArrivalAddress().hashCode());
        result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
        result = prime * result + ((getTicketUnit() == null) ? 0 : getTicketUnit().hashCode());
        result = prime * result + ((getCustomerName() == null) ? 0 : getCustomerName().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", consigneeId=").append(consigneeId);
        sb.append(", customerId=").append(customerId);
        sb.append(", consigneeUnit=").append(consigneeUnit);
        sb.append(", deliveryAddress=").append(deliveryAddress);
        sb.append(", consignee=").append(consignee);
        sb.append(", phone=").append(phone);
        sb.append(", transportType=").append(transportType);
        sb.append(", arrivalAddress=").append(arrivalAddress);
        sb.append(", status=").append(status);
        sb.append(", ticketUnit=").append(ticketUnit);
        sb.append(", customerName=").append(customerName);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}